package com.huiminpay.transaction.service;



import com.huiminpay.transaction.api.IPlatformChannelService;
import com.huiminpay.transaction.convert.PlatformChannelConvert;
import com.huiminpay.transaction.dto.PlatformChannelDTO;
import com.huiminpay.transaction.entity.PlatformChannel;
import com.huiminpay.transaction.mapper.PlatformChannelMapper;
import org.apache.dubbo.config.annotation.Service;
import org.springframework.beans.factory.annotation.Autowired;

import java.util.List;

@Service
public class IPlatformChannelServiceImpl implements IPlatformChannelService {


    @Autowired
    PlatformChannelMapper platformChannelMapper;

    @Override
    public List<PlatformChannelDTO> queryPlatformChannels() {

        List<PlatformChannel> platformChannels =
                platformChannelMapper.selectList(null);

        return PlatformChannelConvert.INSTANCE.listentity2listdto(platformChannels);
    }
}
